26 July, 2019

Heading

Sub-heading

Some text

Plot Code

library(ggplot2)
## Registered S3 methods overwritten by 'ggplot2':
##   method         from 
##   [.quosures     rlang
##   c.quosures     rlang
##   print.quosures rlang
library(plotly)
## 
## Attaching package: 'plotly'
## The following object is masked from 'package:ggplot2':
## 
##     last_plot
## The following object is masked from 'package:stats':
## 
##     filter
## The following object is masked from 'package:graphics':
## 
##     layout
## Generate data
x <- rnorm(100, mean = 50, sd = 5)
y <- rnorm(100, mean = 0, sd = 8) 
plot.df <- data.frame(x = sort(x), y = sort(y))

## Create plot with ggplot2
plot1 <-
    ggplot(data = plot.df, aes(x = x, y = y) ) +
        geom_point(colour = "navy") +
        ggtitle("Plot of x versus y") +
        theme_bw()

Plot

ggplotly(plot1)